package ioc07.controller;

import ioc07.service.UserService;
import lombok.NoArgsConstructor;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Controller;

import javax.annotation.Resource;

/**
 * Author：汤小洋
 * Date：2023-07-04 13:51
 * Description：<描述>
 */
@Controller
@RequiredArgsConstructor // 生成一个包含常量的构造方法
public class UserController {

    private final UserService userService;

    // @Autowired // 如果类中只有一个构造方法，那么@Autowired可以省略
    // public UserController(UserService userService){
    //     this.userService = userService;
    // }

}
